home *** CD-ROM | disk | FTP | other *** search
/ Loadstar 11 / 011.d81 / recipe filer (.txt) < prev    next >
Commodore BASIC  |  2022-08-26  |  4KB  |  128 lines

  1. 0 gosub60000
  2. 5 dima$(20),na$(1000),ni$(100),se$(100)
  3. 10 print"[158]";chr$(14):poke53280,15:poke53281,9
  4. 1000 rem recipe subroutine
  5. 1010 print"[147]      [215]elcome to the [210]ecipe [198]iles[146]"
  6. 1020 print"[208]ress the highlighted[146] letter to:":goto1030
  7. 1025 na$="":nd$="":kl=0:print"[147][215]hich?"
  8. 1030 print"[215][146]rite a recipe
  9. 1035 [153]"(NULL)waitist the recipes on file
  10. 1036 print"[209][146]uit the program"
  11. 1040 geta$:ifa$="" then 1040
  12. 1045 fori=1to3:ifa$<>mid$("wlq",i,1)thennexti:goto1040
  13. 1050 m=i:i=3:nexti:onmgoto1060,1175,2000
  14. 1060 na$="": print"[147]                  [183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][145][145]"
  15. 1061 input"[206]ame of recipe";na$
  16. 1062 iflen(na$)=0then1060
  17. 1065 open2,8,2,"0:recipes,s,r"
  18. 1067 input#2,nm$
  19. 1070 iflen(nm$)=0then close2:goto1090
  20. 1075 ifnm$=na$thenclose2:goto1085
  21. 1077 ifnm$="end"then close2: goto 1090
  22. 1080 goto1067
  23. 1085 print"[212]here is already a recipe by this name  on file. [195]ontinue (y/n)?"
  24. 1086 geta$:ifa$=""then1086
  25. 1087 ifa$="n"then1025
  26. 1088 ifa$<>"y"then1086
  27. 1090 fori=1ton:a$(i)="":nexti:n=0
  28. 1093 print"    [217]ou may type up to 15 lines. [200]it        return at the end of";
  29. 1095 print" each line.":print"    [213]se no punctuation except . and '       as ";
  30. 1096 print"you type. [201]f you need to start       over, type 'r' (return). [212]o ";
  31. 1097 print"end,        hit return on an empty line"
  32. 1098 print
  33. 1100 print"  [183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][145][145]"
  34. 1103 n=n+1:inputa$(n)
  35. 1105 if len(a$(n))=0  orn=15then1115
  36. 1107 ifa$(n)="r"then1060
  37. 1110 goto1100
  38. 1115 open15,8,15:print#15,"s8:"+na$:close 15
  39. 1120 open2,8,2,"0:"+na$+",s,w"
  40. 1125 print#2,na$:print#2," "
  41. 1130 fori=1 to n:print#2,a$(i):next i:print#2,"end"
  42. 1135 close 2
  43. 1140 k=0:l=0: open2,8,2,"0:recipes,s,r"
  44. 1145 k=k+1:input#2,d$
  45. 1150 ifd$="end"then1158
  46. 1151 input#2,na$(k)
  47. 1152 iflen(na$(k))=0then1158
  48. 1155 ifk=val(g$)thennc$=na$(k):na$(k)="":k=k-1:g$=""
  49. 1156 goto1145
  50. 1158 if kl=1thenopen15,8,15:print#15,"s8:"+nc$:close15
  51. 1159 close2:   open15,8,15:print#15,"s8:recipes":close 15
  52. 1160 open2,8,2,"0:recipes,s,w":z$="."
  53. 1162 for i=1tok:ifna$(i)=na$thenl=1
  54. 1163 iflen(na$(i))=0thenk=k-1:goto1168
  55. 1165 print#2,str$(i)+z$:print#2,na$(i)
  56. 1166 nexti
  57. 1167 if kl=1then goto1170
  58. 1168 ifl<>1 thenprint#2,str$(k+1)+z$:print#2,na$
  59. 1170 :print#2,"end":close2: goto1600
  60. 1175 print"[204]ist of recipes on file:"
  61. 1176 open2,8,2,"0:recipes,s,r"
  62. 1179 input#2,e$:input#2,nd$:ife$="end"then1185
  63. 1181 z$=".":ife$=m$+z$thenclose2:goto 1205
  64. 1182 ife$<m$+z$ then1179
  65. 1183 print"";e$;:print nd$:goto1179
  66. 1185 close2
  67. 1187 ifnd$=""then print "[206]one on file yet":goto1025
  68. 1190 print"[210]ead a recipe (y/n)?"
  69. 1192 geta$:ifa$=""then1192
  70. 1194 ifa$= "n"then1700
  71. 1196 ifa$<>"y"then 1192
  72. 1200 print"[215]hich number";:inputm$:goto1176
  73. 1205 n=0:open2,8,2,"0:"+nd$+",s,r"
  74. 1215 n=n+1:input#2,a$(n)
  75. 1220 ifa$(n)="end"  then1250
  76. 1230 goto 1215
  77. 1250 close 2
  78. 1260 print
  79. 1270 fori=1 ton:print"";a$(i):nexti
  80. 1300 m$="":print"[208]rint this recipe (y/n)?
  81. 1302 [161]a$:[139]a$[178]""[167]1302
  82. 1304 [139]a$[178]"n"[167]na$[178]nd$:[137]1600
  83. 1305 [139]a$[179][177]"y"[167]1302
  84. 1308 [153]"(NULL)urn on the printer and press p to      print or n to stop"
  85. 1310 [161]a$:[139]a$[178]""[167]1310
  86. 1312 [139] a$[178]"n"[167]1500
  87. 1315 [139]a$[179][177]"p"[167]1310
  88. 1320 [160]3 :[159]1,4,4:[157]1:[153][199](27);[199](77);:[160]1:[159]1,4,7:[157]1
  89. 1325 [153]"(NULL)ecipe for: "; nd$:[153]
  90. 1330 [129]i[178]2 [164]n[171]1:[153]"";a$(i):[130]i
  91. 1350 [160]1:[159]3,3,1:[157]3
  92. 1500 [153]"atnnother copy (y/n)?"
  93. 1510 [161]a$:[139]a$[178]""[167]1510
  94. 1520 [139]a$[178]"n"[167] 1025
  95. 1530 [139]a$[179][177]"y"[167]1510
  96. 1540 [153]"check printer and press p to print      or n to stop":[137]1310
  97. 1600 [153]"lenopy on backup disk (y/n)?"
  98. 1610 [161]a$:[139]a$[178]""[167]1610
  99. 1620 [139]a$[178]"n" [167] 1025
  100. 1630 [139]a$[179][177]"y"[167] 1610
  101. 1640 [153]"(NULL)ut backup disk in drive and press peek    or (NULL) for stop"
  102. 1650 [161]a$:[139]a$[178]""[167]1650
  103. 1660 [139]a$[178]"n"[167]1025
  104. 1670 [139]a$[179][177]"b" [167] 1650
  105. 1680 [137]1115
  106. 1700 [153]"onstr$elete a recipe (y/n)?"
  107. 1710 [161]a$:[139]a$[178]""[167]1710
  108. 1720 [139]a$[178] "n"[167]1025
  109. 1730 [139]a$[179][177]"y"[167] 1710
  110. 1740 kl[178]1:[153]"(NULL)hich number";:[133]g$:[137]1140
  111. 2000 [153]"loadleft$appy eating!":[137]63000
  112. 60000 t$[178]"                         ":c[178]0:c$[178]"":[153]"load":[151]53281,0
  113. 60030 [153][166]7)""t$:[153][166]7)"      (NULL)ecipe asciler       wait"
  114. 60051 [153][166]7)""t$:[153]:[153][163]18)"by"
  115. 60060 [153]:[153][166]14)"str$ick lenaron"
  116. 60070 [153]:[153][166]12)"lenopyright 1985"
  117. 60080 [153]:[153]:[153]:[153]"     (NULL)(NULL)atnstr$(NULL)(NULL)atn(NULL) is not public domain."
  118. 60090 [153]:[153]"  (NULL)lease respect the author's rights."
  119. 60100 [153]:[153]"      (NULL)ress space bar to continue."
  120. 60110 [129]cc[178]1[164]48:[161]k$:[139]k$[178]" "[167]60130
  121. 60120 [139]cc[178]1[167][153][202](c$,c[170]2,1)"onon";:c[178][168](c)
  122. 60125 [130]:[137]60100
  123. 60130 [153]c$:[142]
  124. 63000 [143]   connect back to loadstar
  125. 63005 [129]dl[178]1[164]3000:[130]
  126. 63010 [153]"loadload"[199](34)"payload"[199](34)",8":[153]"run"
  127. 63020 [151]631,13:[151]632,13:[151]198,2:[128]
  128.